package com.tianji.learning.controller;

import com.tianji.learning.domain.vo.SignResultVO;
import com.tianji.learning.service.ISignRecordService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author liuchun
 * @version 1.0
 * @date 2024/9/7 17:16
 */
@RestController
@RequestMapping("/sign-records")
@Api(tags = "签到相关接口")
public class SignRecordController {


    @Autowired
    private ISignRecordService signRecordService;

    @PostMapping
    @ApiOperation("签到接口")
    private SignResultVO addSignRecord() {
        return signRecordService.addSignRecord();
    }
    @GetMapping
    @ApiOperation("查询签到记录")
    public List<Integer> getSignRecord() {
        return signRecordService.getSignRecord();
    }
}
